from time import sleep

from celery_tasks.main import celery_app
from celery_tasks.sms.yuntongxun.sms import CCP

@celery_app.task(name='send_sms')
def send_sms(mobile,sms_code):
    result = 0
    #2.发送短信验证码(使用云通讯) 5 有效时间  1:短信模板id
    # result = CCP().send_template_sms(mobile,[sms_code,5],1)
    # print(result)  #0表示成功
    sleep(5)
    return result